#ifndef __DP_DEF_H__
#define __DP_DEF_H__

#include <stdint.h>

#define CONST_WINRANGE_EN             (1<<0)
#define CONST_WINVEL_EN               (1<<1)
#define CONST_ANGLE_EN                (1<<2)
																	   
// api不再支持CONST_WINRANGE_FLASH_EN、CONST_WINVEL_FLASH_EN、CONST_ANGLE_FLASH_EN

#define SWEEP_MODE_CONTINUE           (0x01) //chirp continue
#define SWEEP_MODE_CHIRP_SUM_LP       (0x02) //chirp sum low power
#define SWEEP_MODE_CHIRP_SUM          (0x03) //chirp sum 

#define LOWPOWER_EN                (1)
#define LOWPOWER_DIS               (0)


	
typedef struct
{
	uint16_t len;
	uint16_t dstOffsetAddr;
	uint16_t srcInc;
	uint16_t dstInc;
	uint32_t srcFlashAddr;
}WIN_CFG;

typedef struct
{
	int32_t calibAnt2_r;       //0080
	int32_t calibAnt2_i;       //0084
	uint16_t angleDstAddr;     //0088
	uint16_t angleFlashLen;
	uint32_t angleFlashSrcAddr;
	//Win
	WIN_CFG winRange;
	WIN_CFG winVel;
	float chirpT0_msec;      //008C
	float chirpT1_msec;      //0090
	uint32_t prepCfg0;         //0094
	uint32_t prepCfg1;         //0098
	uint32_t prepCfg2;				 //009C
	uint32_t Func1_BaseAddr;   //00A0
	uint16_t Func1_delay;
	uint16_t Func1_OutLen;     //00A4
	uint16_t cycleNum;         //00A8
	uint8_t itv_40M_en;
	uint8_t constEn;           //00AA
	uint8_t constFlashEn;
	uint8_t sweepMode;         //00AB
	uint8_t lowPower;          //
	uint8_t switch_flag;       //借用标志位，暂未计入dataprep crcLen
	uint8_t RFU[48];				   //00BC
	uint16_t crcLen;           //0xFC
	uint16_t crcVal;           //0xFE
}PARAM_DATAPREP;     

#endif
